//
//  MessageBoxView.h
//  CheTaiXian
//
//  Created by Jingjing Huang on 6/07/14.
//  Copyright (c) 2014 Jingjing Huang. All rights reserved.
//

#import <UIKit/UIKit.h>
#import <nbappdev/nbappdev.h>
#import <AVFoundation/AVFoundation.h>
#import "StartRecordView.h"
#define kBottomButtonSideLength 30 //话筒、笑脸、加号按钮的大小
#define kWidth self.frame.size.width
#define kExpressionViewHeight 216
#define kAddViewHeight 216
#define kMessageTextViewHeight self.messageTextView.frame.size.height
#define kMessageTextViewFontHeight 35.5//根据字体设置textview的高度
#define kSetMessageContantOffset 12 //设置textview偏移后 重新设置textview的大小，并顺带设置其他视图

@protocol ChatKeyboardDelegate;

@interface ChatKeyboard : UIView

@property (nonatomic, weak) id <ChatKeyboardDelegate> delegate;
@property (assign, nonatomic) CGFloat maxTextInputViewHeight;
@property (strong, nonatomic) UITextView *messageTextView;
@property (strong,nonatomic)UIButton *expressionBtn;
@property (nonatomic,strong)UIButton *addBtn;
@property (nonatomic,strong)UIButton *startRecordBtn;
@property (nonatomic,strong)UIButton *voiceBtn;
@property (nonatomic,strong)StartRecordView *startRecordView;
@property (nonatomic,assign)BOOL isLocationHidden;

-(void)showAnimationKeyBoardWillChangeFromFrame:(CGRect)beginFrame toFrame:(CGRect)toFrame duration:(CGFloat)duration curve:(UIViewAnimationCurve)curve;

@end

@protocol ChatKeyboardDelegate <NSObject>

@required
- (void)didChangeFrameToHeight:(CGFloat)toHeight;

@optional
//发送消息
-(void)sendMessage:(NSString *)messageStr;
//发送语音
-(void)sendRecord:(NSDictionary *)dict;
//发送图片
-(void)sendImage:(UIImage *)image;
//发送位置
-(void)sendLocation;
@end

